package com.xuecheng.search.service;

import com.xuecheng.commons.model.dto.CoursePubIndexDto;
import com.xuecheng.commons.model.dto.PageRequest;
import com.xuecheng.commons.model.vo.CoursePubIndexVo;
import com.xuecheng.commons.model.vo.PageResponseResult;
import com.xuecheng.commons.model.vo.ResponseResult;

import java.io.IOException;

public interface SearchService {
    //条件查询
    PageResponseResult<CoursePubIndexVo> search(CoursePubIndexDto dto, PageRequest request) throws IOException;
    //同步es索引库
    void updateIndex(Long coursePubId) throws IOException;
    //根据id查询课程发布数据
    ResponseResult<CoursePubIndexVo> findById(Long id) throws IOException;
    //删除索引库数据
    void offlineIndex(Long coursePubId) throws IOException;
}
